<?php
// +----------------------------------------------------------------------
// | ThinkPHP [ WE CAN DO IT JUST THINK ]
// +----------------------------------------------------------------------
// | Copyright (c) 2006~2018 http://thinkphp.cn All rights reserved.
// +----------------------------------------------------------------------
// | Licensed ( http://www.apache.org/licenses/LICENSE-2.0 )
// +----------------------------------------------------------------------
// | Author: liu21st <liu21st@gmail.com>
// +----------------------------------------------------------------------
use think\Route;

Route::domain('adminapi',function(){
    Route::get('/','adminapi/index/index');
    //Route::resource('goods','adminapi/goods');
    Route::get('captcha/:id','\\think\\captcha\\CaptchaController@index');
    Route::get('captcha', 'adminapi/login/captcha');
    Route::post('login','adminapi/login/login');//登录
    Route::post('logout','adminapi/login/logout');//退出登录
    //权限接口
    Route::resource('auths','adminapi/auth',[],['id'=>'\d+']);
    Route::get('nav','adminapi/auth/nav');
    Route::resource('roles','adminapi/role',[],['id'=>'\d+']);
    Route::resource('admin','adminapi/admin',[],['id'=>'\d+']);
    Route::resource('categorys','adminapi/category',[],['id'=>'\d+']);
    Route::post('logo','adminapi/upload/logo');
    Route::post('image','adminapi/upload/image');//多图片上传一张张上传
    Route::post('images','adminapi/upload/images');//多图片多文件
    Route::resource('brands','adminapi/brand',[],['id'=>'\d+']);
    Route::resource('types','adminapi/type',[],['id'=>'\d+']);
});

